package org.extremengine.shape;


/**
 * 无限长的直线。水平线一侧为自由运动区域，另一侧为禁止区域，用构造参数freeSpace来标识。
 * @author yuxing
 * 
 */
public abstract class UnlimitedLine extends Shape {

	public static final int FREE_SPACE_POSITIVE = 1;
	public static final int FREE_SPACE_NEGETIVE = -1;

	// For vertical: -1 means free space in the left of the line, 1 means free space in the right of the line.
	// For horizontal: -1 means free space below the line, 1 means free space above the line.
	protected int freeSpace = FREE_SPACE_POSITIVE;

	public UnlimitedLine() {
		super();
	}

	public UnlimitedLine(int freeSpace) {
		super();
		this.freeSpace = freeSpace;
	}

	@Override
	public void transform(double deltax, double deltay) {
		throw new UnsupportedOperationException();
	}

	public int getFreeSpace() {
		return freeSpace;
	}

	public void setFreeSpace(int freeSpace) {
		this.freeSpace = freeSpace;
	}

}